-
Notifications
You must be signed in to change notification settings - Fork 628
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modify MsgSendTx fields based on audit #2280
Conversation
@@ -50,7 +50,7 @@ func (s msgServer) SendTx(goCtx context.Context, msg *types.MsgSendTx) (*types.M | |||
} | |||
|
|||
// explicitly passing nil as the argument is discarded as the channel capability is retrieved in SendTx. | |||
seq, err := s.Keeper.SendTx(ctx, nil, msg.ConnectionId, portID, msg.PacketData, msg.TimeoutTimestamp) | |||
seq, err := s.Keeper.SendTx(ctx, nil, msg.ConnectionId, portID, msg.PacketData, msg.RelativeTimeout) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this value will be passed correctly in #2257
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #2280 +/- ##
==========================================
+ Coverage 79.54% 79.57% +0.03%
==========================================
Files 175 175
Lines 12069 12118 +49
==========================================
+ Hits 9600 9643 +43
- Misses 2045 2049 +4
- Partials 424 426 +2
|
…hub.com/cosmos/ibc-go into cian/issue#2232-modify-msgsendtx-fields
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Just need to update the error return in ValidateBasic
I think! 🚀
flagPacketTimeoutHeight = "packet-timeout-height" | ||
flagPacketTimeoutTimestamp = "packet-timeout-timestamp" | ||
flagVersion = "version" | ||
flagRelativePacketTimeoutTimestamp = "relative-packet-timeout" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: why not drop the Timestamp
word? In the proto file is called just relative_timeout
and timestamp
has the connotation of a fixed date/time...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it must have been accidentally included! I've removed it now
// Timeout timestamp in absolute nanoseconds since unix epoch. | ||
// The timeout is disabled when set to 0. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like the documentation needs to be moved and updated.
I'd suggest:
// Timeout timestamp in absolute nanoseconds since unix epoch. | |
// The timeout is disabled when set to 0. | |
// Relative timeout timestamp provided will be added to the current block time during transaction execution. | |
// The timeout timestamp must be non-zero. |
This will close #2267
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ay! Nice work! One last suggestion, might be nice to return the error from failed packet data validation
Co-authored-by: colin axnér <[email protected]>
…hub.com/cosmos/ibc-go into cian/issue#2232-modify-msgsendtx-fields
(cherry picked from commit 3c21b5e)
(cherry picked from commit 3c21b5e) Co-authored-by: Cian Hatton <[email protected]>
Description
closes: #2232
closes: #2200
closes: #2267
Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.
docs/
) or specification (x/<module>/spec/
)godoc
comments.Unreleased
section inCHANGELOG.md
Files changed
in the Github PR explorerCodecov Report
in the comment section below once CI passes